<!--
/**
 * comments partial view.
 *
 * @package    FinalsClub
 * @subpackage comments
 * @author     Colin Hom
 */
 
 *This component is for use only in the context of comments on a single material*
 -->
 
<div id="recent-discussions">
	<h2><span>Recent Discussions</span></h2>
	<h3>A list of user comments written in the last 5 days about course notes.</h3>
	<ul>
<?php
 	foreach($comment_pager->getResults() as $key => $comment){
 		/* If a list of comments on different materials is needed */
 ?>
		<li>
			<p class="date"></p>
			<div class="summary">
				<p class="author"><strong></strong> on <?= $material->getHltopic() ?></p>
				<p></p>
			</div>
		</li>
			
<?php } ?>
	</ul>
</div>	

<!-- -->

<h3 class="responses">3 Responses <a href="#">Reply &raquo;</a></h3>
<ul class="comment-list">
	<li>
		<div class="meta">
			<p><?= $comment->getUserRelatedByUserId()->getHlFullName() ?> on <?= $comment->getCreatedAt() ?></p>
			<p class="stars three">3 stars</p>
		</div>
		<p><?= $comment->getContent() ?></p>
	</li>
</ul>
<?= form_tag('comments/create', array('id' => 'leave-reply')) ?>
	<fieldset>
		<div class="left-border">
			<label>Leave a Reply</label>
			<textarea rows="10" cols="60" name="comment"></textarea>
		</div>
		<input type="image" src="./images/btn_leave-reply.gif" alt="Leave a Reply" />
	</fieldset>
</form>

	
